package com.baizhi.dao;

import com.baizhi.entity.User;
import com.baizhi.entity.UserSexDto;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * Created by Administrator on 2019/4/3.
 */
public interface UserDao {
    User login(@Param("user") User user);

    List<User> selectAllUser(@Param("begin")int begin,@Param("size")int size,@Param("username")String username);

    Integer selectAllUserCount(@Param("username")String username);

    List<UserSexDto> selectSexCount();

    List<Map> selectAddressCount();

    void addUser(@Param("user") User user);

    int selectByDayCount(@Param("max") Integer max, @Param("min") Integer min);

    User appselectUser(@Param("userId")Integer userId);

    void appUpdateUser(@Param("userPassword")String userPassword,
                       @Param("userNewPassword")String userNewPassword,@Param("userId") Integer userId);
}
